package com.wnxy.eleba.entity;

import java.io.Serializable;
import java.math.BigDecimal;
import java.util.Date;
import lombok.Data;

/**
 * rider
 * @author 
 */
@Data
public class Rider implements Serializable {
    /**
     * 主键+骑手id
     */
    private Integer id;

    /**
     * 骑手名称
     */
    private String riderName;

    /**
     * 骑手密码
     */
    private String riderPassword;

    /**
     * 骑手电话
     */
    private String riderMobile;

    /**
     * 骑手工资
     */
    private BigDecimal riderSalary;

    /**
     * 骑手提成
     */
    private BigDecimal riderDeduct;

    /**
     * 骑手加入时间
     */
    private Date addTime;

    /**
     * 骑手得分
     */
    private String riderScore;

    /**
     * 骑手头像
     */
    private String riderImages;

    private static final long serialVersionUID = 1L;

    @Override
    public boolean equals(Object that) {
        if (this == that) {
            return true;
        }
        if (that == null) {
            return false;
        }
        if (getClass() != that.getClass()) {
            return false;
        }
        Rider other = (Rider) that;
        return (this.getId() == null ? other.getId() == null : this.getId().equals(other.getId()))
            && (this.getRiderName() == null ? other.getRiderName() == null : this.getRiderName().equals(other.getRiderName()))
            && (this.getRiderPassword() == null ? other.getRiderPassword() == null : this.getRiderPassword().equals(other.getRiderPassword()))
            && (this.getRiderMobile() == null ? other.getRiderMobile() == null : this.getRiderMobile().equals(other.getRiderMobile()))
            && (this.getRiderSalary() == null ? other.getRiderSalary() == null : this.getRiderSalary().equals(other.getRiderSalary()))
            && (this.getRiderDeduct() == null ? other.getRiderDeduct() == null : this.getRiderDeduct().equals(other.getRiderDeduct()))
            && (this.getAddTime() == null ? other.getAddTime() == null : this.getAddTime().equals(other.getAddTime()))
            && (this.getRiderScore() == null ? other.getRiderScore() == null : this.getRiderScore().equals(other.getRiderScore()))
            && (this.getRiderImages() == null ? other.getRiderImages() == null : this.getRiderImages().equals(other.getRiderImages()));
    }

    @Override
    public int hashCode() {
        final int prime = 31;
        int result = 1;
        result = prime * result + ((getId() == null) ? 0 : getId().hashCode());
        result = prime * result + ((getRiderName() == null) ? 0 : getRiderName().hashCode());
        result = prime * result + ((getRiderPassword() == null) ? 0 : getRiderPassword().hashCode());
        result = prime * result + ((getRiderMobile() == null) ? 0 : getRiderMobile().hashCode());
        result = prime * result + ((getRiderSalary() == null) ? 0 : getRiderSalary().hashCode());
        result = prime * result + ((getRiderDeduct() == null) ? 0 : getRiderDeduct().hashCode());
        result = prime * result + ((getAddTime() == null) ? 0 : getAddTime().hashCode());
        result = prime * result + ((getRiderScore() == null) ? 0 : getRiderScore().hashCode());
        result = prime * result + ((getRiderImages() == null) ? 0 : getRiderImages().hashCode());
        return result;
    }

    @Override
    public String toString() {
        StringBuilder sb = new StringBuilder();
        sb.append(getClass().getSimpleName());
        sb.append(" [");
        sb.append("Hash = ").append(hashCode());
        sb.append(", id=").append(id);
        sb.append(", riderName=").append(riderName);
        sb.append(", riderPassword=").append(riderPassword);
        sb.append(", riderMobile=").append(riderMobile);
        sb.append(", riderSalary=").append(riderSalary);
        sb.append(", riderDeduct=").append(riderDeduct);
        sb.append(", addTime=").append(addTime);
        sb.append(", riderScore=").append(riderScore);
        sb.append(", riderImages=").append(riderImages);
        sb.append(", serialVersionUID=").append(serialVersionUID);
        sb.append("]");
        return sb.toString();
    }
}